TfrxReport component

The "TfrxReport" component constitutes the basis of an report. Each such component can contain one report only. The component has ever thing necessary for report loading, designing, previewing, and printing. Let us observe the most important TfrxReport methods.

function LoadFromFile (const FileName: String; ExceptionIfNotFound: Boolean = False): Boolean;

loads a report form from the file with a specified name.

procedure SaveToFile (const FileName: String);

saves the current report form into the file with a specified name.

procedure DesignReport;

calls the report designer.

procedure ShowReport (ClearLastReport: Boolean = True);

runs a report and display s it in the preview window.

"ShowReport" is the only method we would need in this chapter. The only one parameter of this method defines whether the old report should be cleared before building a new one. This parameter is equal to "True" by default, since it is rather convenient to us.